using System;
using System.Collections.Generic;
using System.Text;
using System.Data;

namespace CodeFactory.IDAL
{
    public interface IDbHelper
    {
        IDbConnection Connection { get;}

        string ConnectionString { get;set;}

        ConnectionState State { get;}

        string ConnectionType { get;}

        int QueryNum { get;}

        void Open();

        void Close();

        int ExecuteNonQuery(string sqlString);

        int ExecuteNonQuery(string sqlString, IDbDataParameter[] sqlParas);

        object ExecuteScalar(string sqlString);

        object ExecuteScalar(string sqlString, IDbDataParameter[] sqlParas);

        IDataReader ExecuteDataReader(string sqlString);

        IDataReader ExecuteDataReader(string sqlString, IDbDataParameter[] sqlParas);

        DataTable ExecuteDataTable(string sqlString);

        DataTable ExecuteDataTable(string sqlString, IDbDataParameter[] sqlParas);

        DataTable ExecuteSchemaTable(Guid schema, object[] objs);
    }
}
